<@html>
<script type="text/javascript">
    dojo.require("dijit.dijit");
    dojo.require("dijit.form.Form");
    dojo.require("dijit.form.DateTextBox");
    dojo.require("dijit.form.Button");
    dojo.require("dijit.form.ValidationTextBox");
</script>
<form id="addForm" method="post" dojoType="dijit.form.Form">
<table>
				<tr>
<td>
<@s.text name="code"/>：
</td>
<td>
			<input id="code" name="employee.code" dojoType="dijit.form.ValidationTextBox" required="true" />
</td>
<td>
<@s.text name="type"/>：
</td>
<td>
			<input id="type" name="employee.type" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="name"/>：
</td>
<td>
			<input id="name" name="employee.name" dojoType="dijit.form.ValidationTextBox" required="true" />
</td>
				</tr>
				<tr>
<td>
<@s.text name="ename"/>：
</td>
<td>
			<input id="ename" name="employee.ename" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="birthday"/>：
</td>
<td>
			<input id="birthday" name="employee.birthday" dojoType="dijit.form.DateTextBox" required="true" />
</td>
<td>
<@s.text name="gender"/>：
</td>
<td>
			<input id="gender" name="employee.gender" dojoType="dijit.form.ValidationTextBox" required="true" />
</td>
				</tr>
				<tr>
<td>
<@s.text name="isMarriage"/>：
</td>
<td>
			<input id="isMarriage" name="employee.isMarriage" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="education"/>：
</td>
<td>
			<input id="education" name="employee.education" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="pid"/>：
</td>
<td>
			<input id="pid" name="employee.pid" dojoType="dijit.form.ValidationTextBox" required="true" />
</td>
				</tr>
				<tr>
<td>
<@s.text name="spell"/>：
</td>
<td>
			<input id="spell" name="employee.spell" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="graduateFrom"/>：
</td>
<td>
			<input id="graduateFrom" name="employee.graduateFrom" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="graduateYear"/>：
</td>
<td>
			<input id="graduateYear" name="employee.graduateYear" dojoType="dijit.form.ValidationTextBox" />
</td>
				</tr>
				<tr>
<td>
<@s.text name="dept"/>：
</td>
<td>
			<input id="dept" name="employee.dept" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="workType"/>：
</td>
<td>
			<input id="workType" name="employee.workType" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="title"/>：
</td>
<td>
			<input id="title" name="employee.title" dojoType="dijit.form.ValidationTextBox" />
</td>
				</tr>
				<tr>
<td>
<@s.text name="treeLevel"/>：
</td>
<td>
			<input id="treeLevel" name="employee.treeLevel" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="employer"/>：
</td>
<td>
			<input id="employer" name="employee.employer" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="status"/>：
</td>
<td>
			<input id="status" name="employee.status" dojoType="dijit.form.ValidationTextBox" />
</td>
				</tr>
				<tr>
<td>
<@s.text name="joinTime"/>：
</td>
<td>
			<input id="joinTime" name="employee.joinTime" dojoType="dijit.form.DateTextBox" />
</td>
<td>
<@s.text name="continueTime"/>：
</td>
<td>
			<input id="continueTime" name="employee.continueTime" dojoType="dijit.form.DateTextBox" />
</td>
<td>
<@s.text name="homePhone"/>：
</td>
<td>
			<input id="homePhone" name="employee.homePhone" dojoType="dijit.form.ValidationTextBox" />
</td>
				</tr>
				<tr>
<td>
<@s.text name="officePhone"/>：
</td>
<td>
			<input id="officePhone" name="employee.officePhone" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="mobile"/>：
</td>
<td>
			<input id="mobile" name="employee.mobile" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="email"/>：
</td>
<td>
			<input id="email" name="employee.email" dojoType="dijit.form.ValidationTextBox" />
</td>
				</tr>
				<tr>
<td>
<@s.text name="fax"/>：
</td>
<td>
			<input id="fax" name="employee.fax" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="homeAddr"/>：
</td>
<td>
			<input id="homeAddr" name="employee.homeAddr" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="homeAddrZip"/>：
</td>
<td>
			<input id="homeAddrZip" name="employee.homeAddrZip" dojoType="dijit.form.ValidationTextBox" />
</td>
				</tr>
				<tr>
<td>
<@s.text name="birthPlace"/>：
</td>
<td>
			<input id="birthPlace" name="employee.birthPlace" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="birthPlaceZip"/>：
</td>
<td>
			<input id="birthPlaceZip" name="employee.birthPlaceZip" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="eyesight"/>：
</td>
<td>
			<input id="eyesight" name="employee.eyesight" dojoType="dijit.form.ValidationTextBox" />
</td>
				</tr>
				<tr>
<td>
<@s.text name="kidney"/>：
</td>
<td>
			<input id="kidney" name="employee.kidney" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="sinew"/>：
</td>
<td>
			<input id="sinew" name="employee.sinew" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="permittedLicense"/>：
</td>
<td>
			<input id="permittedLicense" name="employee.permittedLicense" dojoType="dijit.form.ValidationTextBox" />
</td>
				</tr>
				<tr>
<td>
<@s.text name="orgName"/>：
</td>
<td>
			<input id="orgName" name="employee.orgName" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="licenseNo"/>：
</td>
<td>
			<input id="licenseNo" name="employee.licenseNo" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="workRemark"/>：
</td>
<td>
			<input id="workRemark" name="employee.workRemark" dojoType="dijit.form.ValidationTextBox" />
</td>
				</tr>
				<tr>
<td>
<@s.text name="rewardsPunishment"/>：
</td>
<td>
			<input id="rewardsPunishment" name="employee.rewardsPunishment" dojoType="dijit.form.ValidationTextBox" />
</td>
<td>
<@s.text name="remark"/>：
</td>
<td>
			<input id="remark" name="employee.remark" dojoType="dijit.form.ValidationTextBox" />
</td>
		</tr>
</table>
<@listButton/>
</form>
</@html>
<script language="javascript" type="text/javascript">
    dojo.ready(function() {
        //事件注册
        //保存
        dojo.connect(dijit.byId("btnSave"),"onClick", function() {
            //校验表单
            if (dijit.byId("addForm").validate()) {
				//增加列表参数
				var param = dojo.formToObject("addForm");
                dojo.xhrPost({
                    url : "${(path)!}/ast/employee.add.do",
                    content : param,
                    handleAs : "json",
                    load : function(json) {
                        handleJsonMessage({
                            message:json,
                            callback:function() {
                                parent.publish("employee/refresh");
                                parent.closeDialog();
                            }
                        })
                    }
                });
            }
        });
    })
</script>
